<%@ page contentType="text/html;charset=UTF-8" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>

<!DOCTYPE html>
<html lang="en">
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no"/>
    <meta name="renderer" content="webkit">
    <title>后台管理中心</title>
    <link rel="stylesheet" href="${pageContext.request.contextPath}/admin/css/pintuer.css">
    <link rel="stylesheet" href="${pageContext.request.contextPath}/admin/css/admin.css">
    <script src="${pageContext.request.contextPath}/admin/js/jquery.js"></script>
    <script>
        function upVideo() {
            var address = $("#video_address").val();
            var title = $("#video_title").val();
            var presentation = $("#video_presentation").val();
            if (confirm('确认修改?')) {
                location.href = '${pageContext.request.contextPath}/VideoServlet?method=updateVideo&address=' + address + '&title=' + title + '&presentation=' + presentation;
            }
        }
    </script>
</head>
<body>
<div class="panel admin-panel">
    <div class="panel-head"><strong><span class="icon-key"></span> 视频管理</strong></div>
    <div class="body-content">
        <form action="${pageContext.request.contextPath}/VideoServlet?method=updateVideo" method="post">
            <div class="form-x">
                <div class="form-group">
                    <div class="label">
                        <label>视频URL:</label>
                    </div>
                    <div class="field">
                        <input type="text" class="button bg-white-right" name="url" style="width: 40%;"
                               value="${video.address}"/>
                    </div>
                </div>
                <div class="form-group">
                    <div class="label">
                        <label>标题:</label>
                    </div>
                    <div class="field">
                        <input class="input w50" size="50" name="title" value="${video.title}"/>
                    </div>
                </div>
                <div class="form-group">
                    <div class="label">
                        <label>视频简介:</label>
                    </div>
                    <div class="field">
                        <textarea name="presentation" class="input">${video.presentation}</textarea>
                    </div>
                </div>
                <div class="form-group">
                    <div class="label">
                        <label></label>
                    </div>
                    <div class="field">
                        <button class="button bg-main icon-check-square-o" type="submit" onclick="upVideo()"> 提交
                        </button>
                    </div>
                </div>
            </div>
        </form>
    </div>
</div>
</body>
</html>
